<?php
/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2019/7/11
 * Time: 13:22
 */
namespace app\admin\validate;

use think\Validate;

class Smsct extends Validate{
    protected $rule = [
        'client_id'             => 'require',
        'signature'             => 'require|max:20',
        'content'               => 'require|max:500',
        'template_name'         => 'require|max:100',
        'template_code'         => 'require|max:20',
        'status'                => 'in:1,0',
    ];
    protected $message  =   [
        'client_id.require'         => '客户ID不能为空',
        'signature.require'         => '签名不能为空',
        'content.require'           => '内容不能为空',
        'template_name.require'     => '模板名不能为空',
        'template_code.require'     => '模板编号不能为空',
        'signature.max'             => '签名不能超过20个字符',
        'content.max'               => '内容不能超过500个字符',
        'template_name.max'         => '模板名不能超过100个字符',
        'template_code.max'         => '模板编号不能超过20个字符',
        'status.in'                 => '状态不正确',
    ];
}